<template>
  <div @click.prevent="fatherFn">
    <!-- 
      事件修饰符：
      @事件名.prevent => e.preventDafault() 阻止默认行为
      @事件名.stop => e.stopPropagation() 阻止冒泡

    -->
    <a href="http://www.baidu.com" @click.prevent="fn">百度</a>
    <br />
    <a href="http://www.jd.com" @click.prevent.stop="fun">京东</a>
  </div>
</template>

<script>
export default {
  methods: {
    fn() {
      console.log('fn自己事件')
    },
    fun() {
      console.log('fun自己事件')
    },
    fatherFn() {
      console.log('fatherFn自己事件')
    },
  },
}
</script>

<style>
</style>